package be.rubengerits.android.car.dashboard.pager;

import android.support.v4.view.ViewPager;
import android.support.v4.view.ViewPager.OnPageChangeListener;
import android.util.Log;

public class HomeCollectionChangeListener implements OnPageChangeListener {

	private int mPosition = 0;

	@Override
	public void onPageScrollStateChanged(int state) {
		if (state == ViewPager.SCROLL_STATE_IDLE) {
			if (mPosition == 0) {
				Log.e("listener", "pos: " + mPosition);
			}
		}
	}

	@Override
	public void onPageScrolled(int position, float positionOffset, int positionOffsetPixels) {
	}

	@Override
	public void onPageSelected(int position) {
		mPosition = position;
	}

}
